﻿<!--#include file="../inc/common.asp" -->
<!--#include file="waputil.asp" -->
<%
  response.contentType="text/vnd.wap.wml"
  'response.contentType="text/html"
  response.charset=DEFAULT_CHARSET
  response.buffer = true  

  on error resume next
  'on error goto 0

  dim blogItem
  set blogItem = new BlogItemClass
  blogItem.load(clng(request("content_id")))
  
%>
<?xml version="1.0" encoding="<%=DEFAULT_CHARSET%>"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapfourm.org/DTD/wml_1.1.xml">
<wml>
<card title="<%=HTML2WML(blogObj.blogTitle)%>" newcontext="false" ordered="true">
<p>
<b><%=HTML2WML(blogItem.title)%></b><br/>
<%
  if blogItem.isSecret then
    response.write("--保密内容--<br/>")
  end if
  
  dim bodyUrl,bodyTxt,pageno
  pageno = request("pageno_detail")
  
  bodyUrl = "detail.asp?blog_id=" & blogItem.blogId & "&amp;content_id=" & blogItem.itemId & "&amp;pageno_list=" & request("pageno_list")
 
  if not  blogItem.isSecret  or userRightObj.canReadSecret then
  
      if  not isNull(blogItem.excerpt) and not isEmpty(blogItem.excerpt) then
        bodyTxt = HTML2WML(blogItem.excerpt) & "<br/>" 
      end if
      
      if  not isNull(blogItem.detail) and not isEmpty(blogItem.detail) then
      	bodyTxt = bodyTxt & "<br/>" & HTML2WML(blogItem.detail) & "<br/>" 
	  end if
	      
      if  not isNull(blogItem.more) and not isEmpty(blogItem.more) then
      	bodyTxt = bodyTxt & "<br/>" & HTML2WML(blogItem.more) & "<br/>" 
	  end if
      
      response.write wmlTxtPage(bodyTxt, pageno) & "<br/>" 
      response.write wmlTxtPageLink2(bodyTxt, pageno, bodyUrl, "pageno_detail") & "<br/>" 
        
  end if    
%>
</p>
<p>

作者:<%=HTML2WML(blogItem.userName)%><br/>
日期:<%=FORMATDATETIME(blogItem.startDate, vbShortDate)%><br/>
共有<%=blogItem.replyCount%>条评论<br/>
<%
  if blogItem.replyCount>0 then
    dim url
    url = "comments.asp?blog_id=" & blogItem.blogId & "&amp;content_id=" & blogItem.itemId
%>
<a href="<%=url%>&amp;order=&amp;pageno_list=<%=request("pageno_list")%>">查看评论</a><br/>
<%
  end if
  if blogItem.replyCount>1 then
%>
<!--a href="<%=url%>&amp;order=desc">查看最新评论</a><br/-->
<%
  end if
%>
<a href="reply.asp?blog_id=<%=blogItem.blogId%>&amp;content_id=<%=blogItem.itemId%>&amp;pageno_list=<%=request("pageno_list")%>">[发表评论]</a><br/>
<a href="list.asp?blog_id=<%=blogItem.blogId%>&amp;pageno_list=<%=request("pageno_list")%>">[返回<%=HTML2WML(blogObj.blogTitle)%>首页]</a><br/>
<a href="list.asp">[返回最新文章列表]</a>
</p>
<%
  writeBlogOptions
%>
</card>
</wml>
<%
  set blogItem = nothing
  closeDB()
  'session.abandon
%>